package com.ruoyi.pms.domain;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.DataSource;
import com.ruoyi.pms.common.BasePmsEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 任务延期对象 pms_project_task_defer
 * 
 * @author ruoyi
 * @date 2024-12-09
 */
@Data
@TableName(value = "pms_project_task_defer")
public class TaskDefer extends BasePmsEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键id */
    private String id;

    /**
     * 申请0 审核通过1
     */
    private Integer status;

    /** 所在项目id */
    @Excel(name = "所在项目id")
    private String projectId;

    /** 关联任务id */
    @Excel(name = "关联任务id")
    private String taskId;

    /** 开始日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "开始日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date startDate;

    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date lastEndDate;

    /** 延期结束日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "延期结束日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date endDate;

    private Boolean isNew;

    /** 延期理由 */
    @Excel(name = "延期理由")
    private String reason;

    public void setId(String id) 
    {
        this.id = id;
    }

    public String getId() 
    {
        return id;
    }
    public void setProjectId(String projectId) 
    {
        this.projectId = projectId;
    }

    public String getProjectId() 
    {
        return projectId;
    }
    public void setTaskId(String taskId) 
    {
        this.taskId = taskId;
    }

    public String getTaskId() 
    {
        return taskId;
    }
    public void setStartDate(Date startDate) 
    {
        this.startDate = startDate;
    }

    public Date getStartDate() 
    {
        return startDate;
    }
    public void setEndDate(Date endDate) 
    {
        this.endDate = endDate;
    }

    public Date getEndDate() 
    {
        return endDate;
    }
    public void setReason(String reason) 
    {
        this.reason = reason;
    }

    public String getReason() 
    {
        return reason;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("projectId", getProjectId())
            .append("taskId", getTaskId())
            .append("startDate", getStartDate())
            .append("endDate", getEndDate())
            .append("reason", getReason())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
